1. Field of the Invention
The invention relates to a method for executing a system management interrupt. Particularly, the invention relates to a method for protecting a system management interrupt.
2. Description of Related Art
A system management mode (SMM) is a special function of a central processing unit (CPU) of a general computer system. When a system management interrupt (SMI) is triggered to the CPU, the SMM is entered. In the SMM, the CPU executes a SMI handler routine of a basic input output system (BIOS), so as to serve the SMI through the SMI handler routine. Moreover, the SMI handler routine is stored in a system management random access memory (SMRAM).
In recent years, the BIOS mainly uses software SMIs (SW SMIs) to execute some important programs without participation of an operating system (OS), for example, updating the BIOS, enabling or disabling an advanced configuration and power interface (ACPI), inputting an error correction code (ECC), etc. If the SW SMI is improperly used, stability of the system is spoiled, or even the BIOS is damaged which may cause a failure booting.
Since an input output (JO) port of the SW SMI is easy to be obtained, malicious software may use the SW SMI to spoil the system. For example, an IO port address of the SW SMI is generally stored in a fixed ACPI description table (FACP), so that the malicious software can obtain the IO port address of the SW SMI from the FACP. Alternatively, the malicious software can obtain the IO port address of the SW SMI through a manufacture identifier of a south bridge chip.